package com.smcdd.cdb.dbo.cdb_dbo.service.entity;

import android.annotation.SuppressLint;
import android.os.Parcel;
import android.os.Parcelable;

import java.io.Serializable;
import java.util.List;

/**
 * 作者：Administrator on 2017/7/18 11:01
 * 邮箱：zhanghuaiha@gmail.com
 *  待维护
 */

public class Tain_v2 implements Parcelable {

        /**
         * id : 5761
         * store_info_id : 2409
         * status : 0
         * already_num : 3
         * ok_num : 0
         * update_time : 2017-07-25 14:41:58
         * created : 2017-07-25 14:41:55
         * charging_info_ids : 4976,4977,4978
         * date : 2017-07-25
         * avg_online_num : 0
         * "online_num": 0,     //实时在线
         "offline_num": 0,    //实时离线
         "avg_online_num": 0         //平均在线
         "mima_already_num": "0",   //已铺密码设备
         "mima_ok_num": "0",        //密码达标设备
         "mima_charging_info_ids": null,  // 具体密码设备de id
         "maintained_status":0,  //0否1是 店铺当日是否维护了
         "wifi_already_maintained_num":0, //已维护店铺数量
         "wifi_already_maintained_ids":0, //已维护设备ids
         * store_info : {"id":"2409","uid":"39","name":"后厨妈妈（万金广场）","contact":"刘","tel":"18971457637","remark":null,"created":"2017-07-14 16:28:41","latitude":"30.53145600","longitude":"114.31718600","province_id":"17","city_id":"920","area_id":"925","specific_address":"万金负一楼","province_name":"湖北省","city_name":"武汉市","area_name":"武昌区","status":"1","position":"12","position_name":"餐饮酒店","img_url":"http://qncdn.sprxt.com/0e3914814746d6b3b22de36f1311f1a8.jpg","from_type":"1","employee_id":"39","delete_time":null,"update_time":"2017-07-14 16:28:41","type":"1","lay_time":"2017-07-15 12:50:46"}
         */

        private String id;
        private String store_info_id;
        private String status;
        private String already_num;
        private String ok_num;
        private String update_time;
        private String created;
        private String charging_info_ids;
        private String date;
        private String mima_already_num;
        private int maintained_status;
        private int wifi_already_maintained_num;

    protected Tain_v2(Parcel in) {
        id = in.readString();
        store_info_id = in.readString();
        status = in.readString();
        already_num = in.readString();
        ok_num = in.readString();
        update_time = in.readString();
        created = in.readString();
        charging_info_ids = in.readString();
        date = in.readString();
        mima_already_num = in.readString();
        maintained_status = in.readInt();
        wifi_already_maintained_num = in.readInt();
        wifi_already_maintained_ids = in.readString();
        sortLetters = in.readString();
        mima_ok_num = in.readString();
        mima_charging_info_ids = in.readString();
        online_num = in.readString();
        offline_num = in.readString();
        avg_online_num = in.readString();
        store_info = in.readParcelable(StoreInfoBean.class.getClassLoader());
    }

    public static final Creator<Tain_v2> CREATOR = new Creator<Tain_v2>() {
        @Override
        public Tain_v2 createFromParcel(Parcel in) {
            return new Tain_v2(in);
        }

        @Override
        public Tain_v2[] newArray(int size) {
            return new Tain_v2[size];
        }
    };

    public int getMaintained_status() {
        return maintained_status;
    }

    public void setMaintained_status(int maintained_status) {
        this.maintained_status = maintained_status;
    }

    public int getWifi_already_maintained_num() {
        return wifi_already_maintained_num;
    }

    public void setWifi_already_maintained_num(int wifi_already_maintained_num) {
        this.wifi_already_maintained_num = wifi_already_maintained_num;
    }

    public String getWifi_already_maintained_ids() {
        return wifi_already_maintained_ids;
    }

    public void setWifi_already_maintained_ids(String wifi_already_maintained_ids) {
        this.wifi_already_maintained_ids = wifi_already_maintained_ids;
    }

    private String wifi_already_maintained_ids;

    public String getSortLetters() {
        return sortLetters;
    }

    public void setSortLetters(String sortLetters) {
        this.sortLetters = sortLetters;
    }

    private String sortLetters;  //显示数据拼音的首字母
        private String mima_ok_num;

    public String getMima_already_num() {
        return mima_already_num;
    }

    public void setMima_already_num(String mima_already_num) {
        this.mima_already_num = mima_already_num;
    }

    public String getMima_ok_num() {
        return mima_ok_num;
    }

    public void setMima_ok_num(String mima_ok_num) {
        this.mima_ok_num = mima_ok_num;
    }

    public String getMima_charging_info_ids() {
        return mima_charging_info_ids;
    }

    public void setMima_charging_info_ids(String mima_charging_info_ids) {
        this.mima_charging_info_ids = mima_charging_info_ids;
    }

    private String mima_charging_info_ids;

    public String getOnline_num() {
        return online_num;
    }

    public void setOnline_num(String online_num) {
        this.online_num = online_num;
    }

    public String getOffline_num() {
        return offline_num;
    }

    public void setOffline_num(String offline_num) {
        this.offline_num = offline_num;
    }

    public String getAvg_online_num() {
        return avg_online_num;
    }

    public void setAvg_online_num(String avg_online_num) {
        this.avg_online_num = avg_online_num;
    }

    private String online_num;
        private String offline_num;
        private String avg_online_num;
        private StoreInfoBean store_info;

        public String getId() {
            return id;
        }

        public void setId(String id) {
            this.id = id;
        }

        public String getStore_info_id() {
            return store_info_id;
        }

        public void setStore_info_id(String store_info_id) {
            this.store_info_id = store_info_id;
        }

        public String getStatus() {
            return status;
        }

        public void setStatus(String status) {
            this.status = status;
        }

        public String getAlready_num() {
            return already_num;
        }

        public void setAlready_num(String already_num) {
            this.already_num = already_num;
        }

        public String getOk_num() {
            return ok_num;
        }

        public void setOk_num(String ok_num) {
            this.ok_num = ok_num;
        }

        public String getUpdate_time() {
            return update_time;
        }

        public void setUpdate_time(String update_time) {
            this.update_time = update_time;
        }

        public String getCreated() {
            return created;
        }

        public void setCreated(String created) {
            this.created = created;
        }

        public String getCharging_info_ids() {
            return charging_info_ids;
        }

        public void setCharging_info_ids(String charging_info_ids) {
            this.charging_info_ids = charging_info_ids;
        }

        public String getDate() {
            return date;
        }

        public void setDate(String date) {
            this.date = date;
        }


        public StoreInfoBean getStore_info() {
            return store_info;
        }

        public void setStore_info(StoreInfoBean store_info) {
            this.store_info = store_info;
        }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(id);
        dest.writeString(store_info_id);
        dest.writeString(status);
        dest.writeString(already_num);
        dest.writeString(ok_num);
        dest.writeString(update_time);
        dest.writeString(created);
        dest.writeString(charging_info_ids);
        dest.writeString(date);
        dest.writeString(mima_already_num);
        dest.writeInt(maintained_status);
        dest.writeInt(wifi_already_maintained_num);
        dest.writeString(wifi_already_maintained_ids);
        dest.writeString(sortLetters);
        dest.writeString(mima_ok_num);
        dest.writeString(mima_charging_info_ids);
        dest.writeString(online_num);
        dest.writeString(offline_num);
        dest.writeString(avg_online_num);
        dest.writeParcelable(store_info, flags);
    }

    public static class StoreInfoBean implements Parcelable {
            /**
             * id : 2409
             * uid : 39
             * name : 后厨妈妈（万金广场）
             * contact : 刘
             * tel : 18971457637
             * remark : null
             * created : 2017-07-14 16:28:41
             * latitude : 30.53145600
             * longitude : 114.31718600
             * province_id : 17
             * city_id : 920
             * area_id : 925
             * specific_address : 万金负一楼
             * province_name : 湖北省
             * city_name : 武汉市
             * area_name : 武昌区
             * status : 1
             * position : 12
             * position_name : 餐饮酒店
             * img_url : http://qncdn.sprxt.com/0e3914814746d6b3b22de36f1311f1a8.jpg
             * from_type : 1
             * employee_id : 39
             * delete_time : null
             * update_time : 2017-07-14 16:28:41
             * store_type:0 1  表示 WiFi 店铺  4=密码店铺
             * type : 1
             * lay_time : 2017-07-15 12:50:46
             *  "offine_num": "0",
             "mima_num": "0"
             */

            private String id;
            private String uid;
            private String name;
            private String contact;
            private String tel;
            private Object remark;
            private String created;
            private String latitude;
            private String longitude;
            private String province_id;
            private String city_id;
            private String area_id;
            private String specific_address;
            private String province_name;
            private String city_name;
            private String area_name;
            private String status;
            private String position;
            private String position_name;
            private String img_url;
            private String from_type;
            private String employee_id;
            private Object delete_time;
            private String update_time;
            private String type;
            private String lay_time;

        protected StoreInfoBean(Parcel in) {
            id = in.readString();
            uid = in.readString();
            name = in.readString();
            contact = in.readString();
            tel = in.readString();
            created = in.readString();
            latitude = in.readString();
            longitude = in.readString();
            province_id = in.readString();
            city_id = in.readString();
            area_id = in.readString();
            specific_address = in.readString();
            province_name = in.readString();
            city_name = in.readString();
            area_name = in.readString();
            status = in.readString();
            position = in.readString();
            position_name = in.readString();
            img_url = in.readString();
            from_type = in.readString();
            employee_id = in.readString();
            update_time = in.readString();
            type = in.readString();
            lay_time = in.readString();
            store_type = in.readString();
        }

        public static final Creator<StoreInfoBean> CREATOR = new Creator<StoreInfoBean>() {
            @Override
            public StoreInfoBean createFromParcel(Parcel in) {
                return new StoreInfoBean(in);
            }

            @Override
            public StoreInfoBean[] newArray(int size) {
                return new StoreInfoBean[size];
            }
        };

        public String getStore_type() {
                return store_type;
            }

            public void setStore_type(String store_type) {
                this.store_type = store_type;
            }

            private String store_type;

            public String getId() {
                return id;
            }

            public void setId(String id) {
                this.id = id;
            }

            public String getUid() {
                return uid;
            }

            public void setUid(String uid) {
                this.uid = uid;
            }

            public String getName() {
                return name;
            }

            public void setName(String name) {
                this.name = name;
            }

            public String getContact() {
                return contact;
            }

            public void setContact(String contact) {
                this.contact = contact;
            }

            public String getTel() {
                return tel;
            }

            public void setTel(String tel) {
                this.tel = tel;
            }

            public Object getRemark() {
                return remark;
            }

            public void setRemark(Object remark) {
                this.remark = remark;
            }

            public String getCreated() {
                return created;
            }

            public void setCreated(String created) {
                this.created = created;
            }

            public String getLatitude() {
                return latitude;
            }

            public void setLatitude(String latitude) {
                this.latitude = latitude;
            }

            public String getLongitude() {
                return longitude;
            }

            public void setLongitude(String longitude) {
                this.longitude = longitude;
            }

            public String getProvince_id() {
                return province_id;
            }

            public void setProvince_id(String province_id) {
                this.province_id = province_id;
            }

            public String getCity_id() {
                return city_id;
            }

            public void setCity_id(String city_id) {
                this.city_id = city_id;
            }

            public String getArea_id() {
                return area_id;
            }

            public void setArea_id(String area_id) {
                this.area_id = area_id;
            }

            public String getSpecific_address() {
                return specific_address;
            }

            public void setSpecific_address(String specific_address) {
                this.specific_address = specific_address;
            }

            public String getProvince_name() {
                return province_name;
            }

            public void setProvince_name(String province_name) {
                this.province_name = province_name;
            }

            public String getCity_name() {
                return city_name;
            }

            public void setCity_name(String city_name) {
                this.city_name = city_name;
            }

            public String getArea_name() {
                return area_name;
            }

            public void setArea_name(String area_name) {
                this.area_name = area_name;
            }

            public String getStatus() {
                return status;
            }

            public void setStatus(String status) {
                this.status = status;
            }

            public String getPosition() {
                return position;
            }

            public void setPosition(String position) {
                this.position = position;
            }

            public String getPosition_name() {
                return position_name;
            }

            public void setPosition_name(String position_name) {
                this.position_name = position_name;
            }

            public String getImg_url() {
                return img_url;
            }

            public void setImg_url(String img_url) {
                this.img_url = img_url;
            }

            public String getFrom_type() {
                return from_type;
            }

            public void setFrom_type(String from_type) {
                this.from_type = from_type;
            }

            public String getEmployee_id() {
                return employee_id;
            }

            public void setEmployee_id(String employee_id) {
                this.employee_id = employee_id;
            }

            public Object getDelete_time() {
                return delete_time;
            }

            public void setDelete_time(Object delete_time) {
                this.delete_time = delete_time;
            }

            public String getUpdate_time() {
                return update_time;
            }

            public void setUpdate_time(String update_time) {
                this.update_time = update_time;
            }

            public String getType() {
                return type;
            }

            public void setType(String type) {
                this.type = type;
            }

            public String getLay_time() {
                return lay_time;
            }

            public void setLay_time(String lay_time) {
                this.lay_time = lay_time;
            }

        @Override
        public int describeContents() {
            return 0;
        }

        @Override
        public void writeToParcel(Parcel dest, int flags) {
            dest.writeString(id);
            dest.writeString(uid);
            dest.writeString(name);
            dest.writeString(contact);
            dest.writeString(tel);
            dest.writeString(created);
            dest.writeString(latitude);
            dest.writeString(longitude);
            dest.writeString(province_id);
            dest.writeString(city_id);
            dest.writeString(area_id);
            dest.writeString(specific_address);
            dest.writeString(province_name);
            dest.writeString(city_name);
            dest.writeString(area_name);
            dest.writeString(status);
            dest.writeString(position);
            dest.writeString(position_name);
            dest.writeString(img_url);
            dest.writeString(from_type);
            dest.writeString(employee_id);
            dest.writeString(update_time);
            dest.writeString(type);
            dest.writeString(lay_time);
            dest.writeString(store_type);
        }
    }

}
